Class Encryption

Summary

Fully Qualified Name: CodeIgniter\Encryption\Encryption

Description

CodeIgniter Encryption Manager

Provides two-way keyed encryption via PHP's Sodium and/or OpenSSL extensions. This class determines the driver, cipher, and mode to use, and then initializes the appropriate encryption handler.

Methods

Name Description Defined By
__construct() Class constructor Encryption
__get() __get() magic, providing readonly access to some of our protected properties Encryption
__isset() __isset() magic, providing checking for some of our protected properties Encryption
createKey() Create a random key Encryption
initialize() Initialize or re-initialize an encrypter Encryption

Method Details

__construct()

Class constructor

Parameter Name Type Description
$config \BaseConfig Configuration

Returns: void

__get()

__get() magic, providing readonly access to some of our protected properties

Parameter Name Type Description
$key string Property

Returns: mixed

__isset()

__isset() magic, providing checking for some of our protected properties

Parameter Name Type Description
$key string Property

Returns: bool

createKey()

Create a random key

Parameter Name Type Description
$length int Output

Returns: string

initialize()

Initialize or re-initialize an encrypter

Parameter Name Type Description
$config \BaseConfig Configuration

Returns: \CodeIgniter\Encryption\EncrypterInterface

Top